/**      
 * @file		GuessMyNumber.cpp
 * @description		This sample generates a random number and asks the user to guess
 *			what number has been generated. If the user types the correct number
 *			that was generated, the program states that the correct number was
 *			guess, otherwise it states what number was generated.
 * @course		CSCI 123 Section 00000
 * @assignment 
 * @date		mm/dd/yyyy
 * @author		Brad Rippe (00000000) brippe@fullcoll.edu
 * @version		1.0
 */
#include <iostream>
#include <ctime>
#include <cstdlib>
using namespace std;

/**
 * @return zero if the application executes successfully
 */
int main() {
	srand((unsigned)time(0));
	int myNum = rand()%11;

	cout << "Type a number between 1 and 10\n> ";
	
	int yourNum;
	cin >> yourNum;
	
	if(myNum == yourNum) {
		cout << "You guessed correctly!\n";
	} else {
		cout << "Sorry! My number was " << myNum << endl;
	}
	return 0;
}
